<include file="Public:head" />

<div style="display: {$newrecord}">
	<h2>添加新记录</h2>
	<div class="center_div">
		<form action="__URL__/add" method="post">
			<table id="rank_table">
				<tr>
					<th>类型</th>
					<th>赛制</th>
					<th>正方一</th>
					<th>正方二</th>
					<th>反方一</th>
					<th>反方二</th>
					<th>比分</th>
					<th>比赛系数</th>
					<th></th>
				</tr>
				<tr bgcolor="#FFFFFF">
					<td>
						<select name="match_type">
							<option value="single">
								单打
							</option>
							<option value="double">
								双打
							</option>
							<option value="small">
								小球
							</option>
						</select>
					</td>
					<td>
						<select name="match_rule">
							<option value="11scores">
								11分
							</option>
						</select>
					</td>
					
					<td>
						<select name="pros_player1">
							<volist name="userlist" id="vo">
								<option value="{$vo.user_id}">
									{$vo.username}
								</option>
							</volist>
						</select>
					</td>
					<td>
						<select name="pros_player2">
							<option value="">
							</option>
							<volist name="userlist" id="vo">
								<option value="{$vo.user_id}">
									{$vo.username}
								</option>
							</volist>
						</select>
					</td>
					<td>
						<select name="cons_player1">
							<volist name="userlist" id="vo">
								<option value="{$vo.user_id}">
									{$vo.username}
								</option>
							</volist>
						</select>
					</td>
					<td>
						<select name="cons_player2">
							<option value="">
							</option>
							<volist name="userlist" id="vo">
								<option value="{$vo.user_id}">
									{$vo.username}
								</option>
							</volist>
						</select>
					</td>
					
					<td>
						<input type="text" name="pros_score" maxlength="2" style="width:15px">
						:
						<input type="text" name="cons_score" maxlength="2" style="width:15px">
					</td>
					<td>
						<select name="match_coef">
							<option value="1.0">
								1.0
							</option>
							<option value="1.2">
								1.2
							</option>
						</select>
					</td>
					<td><input type="submit" value="提交"></td>
				</tr>
			</table>
		</form>
	</div>
</div>

<h2>历史记录</h2>
<div class="center_div">
	<table id="rank_table">
		<tr>
			<th>ID</th>
			<th>类型</th>
			<th>赛制</th>
			<th>正方一</th>
			<th>正方二</th>
			<th>反方一</th>
			<th>反方二</th>
			<th>比分</th>
			<th>比赛系数</th>
			<th>日期</th>
			<th>记录人</th>
		</tr>
		<volist name="recordlist" id="vo">
		<tr title="{$vo.detail}" bgcolor="#FFFFFF">
			<td>{$vo.match_id}</td>
			<td>{$vo.match_type}</td>
			<td>{$vo.match_rule}</td>
			<td><font color={$vo.color1}>{$vo.pros_player1}</font></td>
			<td><font color={$vo.color2}>{$vo.pros_player2}</font></td>
			<td><font color={$vo.color3}>{$vo.cons_player1}</font></td>
			<td><font color={$vo.color4}>{$vo.cons_player2}</font></td>
			<td>{$vo.score}</td>
			<td>{$vo.match_coef}</td>
			<td>{$vo.match_date}</td>
			<td><font color={$vo.color5}>{$vo.recorder}</font></td>
		</tr>
		</volist>
	</table>
</div>

<include file="Public:tail" />